package com.alisls.shequtao.service.user.config;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.web.client.RestTemplate;

/**
 * 用户服务配置类
 *
 * @author Ke Wang
 */
@Configuration
@RefreshScope
public class UserConfig {

	@Bean
	public RestTemplate restTemplate() {
		return new RestTemplate();
	}

	@Bean(name = "serviceProp")
	@ConfigurationProperties(prefix = "service")
	public ServiceProp serviceProp() {
		return new ServiceProp();
	}
	
}
